home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d13 / pwr14e.arc / PBCLONE.PWR < prev    next >
Text File  |  1990-12-27  |  5KB  |  130 lines

  1. Variable      FColor,1
  2. Variable      BColor,1
  3. Variable      CAttr,1
  4. Variable      Use2Flop,1,"Y"
  5. Variable      UseHD,1,"N"
  6. Variable      Source,79,"A:"
  7. Variable      Target,79,"B:"
  8. Variable      WorkDisk,79
  9. Variable      DelWork,1,"N"
  10. Variable      Work,79
  11. Variable      Msg,80
  12. Variable      InChar,1
  13. ?Color        FColor,BColor,CAttr       ;save curr colors
  14. Clear                                   ;clear the screen
  15. WriteLine     "This PowerBatch program will produce an evaluation copy of PowerBatch for you"
  16. WriteLine     "to give to a friend or associate. If you have 2 floppy disk drives, both will"
  17. WriteLine     "be utilized to make the copy. If you have only one drive, enter A for both"
  18. WriteLine     "source and destination and the files will be copied to your hard disk and from"
  19. WriteLine     "your hard disk to a new disk in your floppy drive."
  20. WriteLine     ""
  21. Write         "Enter the source drive letter containing the PowerBatch files "
  22. ReadUpKey     Source
  23. WriteLine     ""
  24. Write         "Enter the source directory name "
  25. ReadStr       Work
  26. WriteLine     ""
  27. Write         "Enter the target drive letter to receive the PowerBatch files "
  28. ReadUpKey     Target
  29. WriteLine     ""
  30. Compare       Source,Target,2Drives,2Drives
  31. Concat        Source,":"              ;ie A:
  32. Concat        Source,Work             ;A:\Work...
  33. Write         "Enter the Drive letter to be used as a work drive "
  34. ReadUpKey     WorkDisk
  35. WriteLine     ""
  36. Concat          WorkDisk,":"            ;use this as a work dir
  37. Concat        Work,"Copy PowerBatch from ",Source
  38. Concat          Work," to "
  39. Concat          Work,Target
  40. Concat          Work,": using work drive "
  41. Concat          Work,WorkDisk
  42. Concat          Work," [Y/N] "
  43. Write          Work
  44. ReadUpKey      InChar
  45. WriteLine      ""
  46. Compare       InChar,"Y",Finis,Finis
  47. Concat          WorkDisk,"\{PB$WRK}"   ;use this as a work dir
  48. ?DirExist     WorkDisk,WorkExist      ;does it exist
  49. SetVar        DelWork,"Y"             ;delete it when were done
  50. Write         "Making directory "
  51. WriteLine     WorkDisk
  52. MKDIR         WorkDisk                ;create the work dir
  53.  
  54. Label         WorkExist
  55. Concat        Work,Source," "         ;cmd line parms are delimited by spaces
  56. Concat        Work,WorkDisk
  57. WriteLine     "Copy PowerBatch files to work directory"
  58. MoveSub       Work                    ;execute subroutine
  59. Compare       ErrorLevel,0,Finis
  60. Concat        Msg,"Remove PowerBatch disk from ",Source
  61. Concat        Msg," and replace with blank disk. Press Y when ready."
  62. ReadYN        Msg,InChar
  63. WriteLine     ""
  64. Concat        Work,WorkDisk," "      ;build cmd line for copy
  65. Concat        Work,Target
  66. Concat        Work,":"
  67. MoveSub       Work                    ;now copy from work disk to floppy
  68. Compare       ErrorLevel,0,Finis
  69. WriteLine     ""
  70. Write         "The disk in "
  71. Write         Target
  72. WriteLine     " is now a copy of PowerBatch."
  73. WriteLine     "You may remove and label the disk while I clean up the work disk."
  74. WriteLine     ""
  75. GoTo          CopyExit
  76.  
  77. Label         2Drives
  78. Concat        Source,":"              ;add : to drive letter
  79. Concat        Target,":"
  80. Concat        Source,Work             ;add the dir to drive on source
  81. Concat          Work,"Copy PowerBatch from ",Source
  82. Concat          Work," to "
  83. Concat          Work,Target
  84. Concat          Work," [Y/N] "
  85. Write          Work
  86. ReadUpKey      InChar
  87. WriteLine      ""
  88. Compare       InChar,"Y",Finis,Finis
  89. Concat        Work,Source," "         ;build entire command in work
  90. Concat        Work,Target
  91. MoveSub       Work
  92. Compare       ErrorLevel,0,Finis
  93. Write         "The disk in "
  94. Write         Target
  95. WriteLine     " is now a copy of PowerBatch."
  96. WriteLine     ""
  97. GoTo          Finis
  98.  
  99. Label         CopyExit
  100. WriteLine     "Delete files from work disk"
  101. Concat        Work,WorkDisk,"\README.1ST"
  102. Erase         Work
  103. Concat        Work,WorkDisk,"\PBINSTAL.EXE"
  104. Erase         Work
  105. Concat        Work,WorkDisk,"\POWERMAK.EXE"
  106. Erase         Work
  107. Concat        Work,WorkDisk,"\SMLMODEL.MDL"
  108. Erase         Work
  109. Concat          Work,WorkDisk,"\KEYID.EXE"
  110. Erase          Work
  111. Concat        Work,WorkDisk,"\POWERBAT.DOC"
  112. Erase         Work
  113. Concat        Work,WorkDisk,"\DOSEX1.BAT"
  114. Erase         Work
  115. Concat        Work,WorkDisk,"\*.PWR"
  116. Erase         Work
  117. Concat        Work,WorkDisk,"\DELETEPB.EXE"
  118. Erase         Work
  119. Concat        Work,WorkDisk,"\*.FRM"
  120. Erase         Work
  121. Concat        Work,WorkDisk,"\VENDOR.DOC"
  122. Erase         Work
  123. Concat        Work,WorkDisk,"\SYSOP.DOC"
  124. Erase         Work
  125. Compare       DelWork,"Y",Finis,Finis
  126. WriteLine     "Remove work directory"
  127. RMDIR         WorkDisk
  128.  
  129. Label         Finis
  130.